﻿<%@ Page Title="Rainbow Report" Language="C#" MasterPageFile="~/masterpage.master" AutoEventWireup="true" CodeFile="RainbowReport.aspx.cs" Inherits="RainbowReport" %>

<%@ Register src="ucLetters.ascx" tagname="ucLetters" tagprefix="uc2" %>
<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
  <link rel="stylesheet" type="text/css" href="css/admin.css" />
  <script language="javascript" type="text/javascript">
      var controldivname = 'ctl00_ContentPlaceHolder1_rgRainbowReport';
  </script>
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<table width="95%" cellpadding="0" cellspacing="0" border="0">
<tr>

<style>
    .GridHeader_Default
    {
        padding-top:0px !important;
        padding-bottom:0px !important;
    }
</style>

<td colspan="2">
	<div class="wrap4"><div class="abcd">

	<table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
	        <td align="left" valign="middle">
                <asp:Label ID="Label1" runat="server" Text="Student Name:"></asp:Label>
			    <asp:TextBox ID="tbName" runat="server" Width="100"></asp:TextBox>
                <asp:Label ID="Label2" runat="server" Text="Section:"></asp:Label>
                <asp:DropDownList ID="dropLstSection" runat="server" Width="200" CssClass="filter-ddl" style="padding:2px;">
                    <asp:ListItem>Select a Section</asp:ListItem>
                    <asp:ListItem>Select b Section</asp:ListItem>
                    <asp:ListItem>Select c Section</asp:ListItem>
                </asp:DropDownList>
                <!-- TODO: change the ImageUrl -->
                <asp:ImageButton ID="btnGo"  runat="server" ImageUrl="images/go_button2.png" 
			        Text="Search" style="height: 17px" OnClick="btnGo_Click" />
                
            </td>
            <td>
                <label style="float: left">Legend:</label>
                <label style="background-color: red; float: left; margin-left:3px; color:White;">0-59.99</label>
                <label style="background-color: yellow; float: left; margin-left:3px; color:Black;">60-69.99</label>
                <label style="background-color: green; float: left; margin-left:3px; color:White;">70-100</label>
            </td>
            <td align="right"><asp:ImageButton ImageUrl="Images/excel_icon2.png" ID="lbExport" runat="server" 
		        onclick="lbExport_Click" ToolTip="Export to Excel" ></asp:ImageButton>
            </td>
		</tr>
	</table>
	
<div class="clr"></div>
</div></div>
<div class="clr"></div>
</td>
</tr>
</table>

<table style="width:900px;">
    <tr>
        <td align="center">

            <telerik:radscriptmanager ID="RadScriptManager1" Runat="server">
            </telerik:radscriptmanager>

            <telerik:RadGrid runat="server" ID="rgRainbowReport"  Height="400px" Width="900px" GridLines="Both"
                             AllowPaging="True" AllowSorting="True" AllowFilteringByColumn="True" PageSize="20" AutoGenerateColumns="False"
                             OnNeedDataSource="rgRainbowReport_NeedDataSource"
                             OnItemCreated="rgRainbowReport_ItemCreated">
                             <ClientSettings>
                                <Scrolling AllowScroll="True" SaveScrollPosition="true" UseStaticHeaders="True"></Scrolling>
                             </ClientSettings>
                             <HeaderStyle  Font-Bold="True" Font-Underline="False" Font-Size="9" HorizontalAlign="Center"  />
                             <MasterTableView Width="100%" DataKeyNames="GRADE_TO_DATE">
                                <Columns>
                                    <telerik:GridBoundColumn DataType="System.String" DataField="STUDENT_NAME" HeaderText="Student Name" ReadOnly="true" HeaderStyle-HorizontalAlign="Center"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Left"/>
                                    <telerik:GridBoundColumn DataType="System.String" DataField="STUDENT_ID" HeaderText="Student ID" ReadOnly="true" HeaderStyle-HorizontalAlign="Center"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Right"/>
                                    <telerik:GridBoundColumn DataType="System.String" DataField="course_name" HeaderText="Section Name" ReadOnly="true" HeaderStyle-HorizontalAlign="Center"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Left"/>
                                    <telerik:GridBoundColumn DataType="System.String" DataField="OVERDUE_ASSIGNMENTS" HeaderText="Overdue Assignments" ReadOnly="true" HeaderStyle-HorizontalAlign="Center"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Right">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataType="System.String" UniqueName="GRADE_TO_DATE" DataField="GRADE_TO_DATE2" HeaderText="Grade to date" ReadOnly="true"
                                        ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Right" HeaderStyle-HorizontalAlign="Center">
                                     </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataType="System.String" DataFormatString="{0:MM/dd/yy}" DataField="LAST_ASSIGNMENT_DATE" HeaderText="Last assignment date" ReadOnly="true"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Center" HeaderStyle-HorizontalAlign="Center"/>  
                                    <telerik:GridBoundColumn DataType="System.String" DataFormatString="{0:MM/dd/yy}" DataField="LAST_ASSIGNMENT_DATE" HeaderText="Actual start date" ReadOnly="true"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Center" HeaderStyle-HorizontalAlign="Center"/>  
                                    <telerik:GridBoundColumn DataType="System.String" DataFormatString="{0:MM/dd/yy}" DataField="FIRST_DATE_ACCESSED" HeaderText="First date accessed" ReadOnly="true"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Center" HeaderStyle-HorizontalAlign="Center"/>    
                                    <telerik:GridBoundColumn DataType="System.String" DataField="EMAIL" HeaderText="Email" ReadOnly="true" HeaderStyle-HorizontalAlign="Center"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Left" FilterControlWidth="128"/>
                                    <telerik:GridBoundColumn DataType="System.String" DataField="phone" HeaderText="Student Phone" ReadOnly="true" HeaderStyle-HorizontalAlign="Center"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Left"/>  
                                    <telerik:GridBoundColumn DataType="System.String" DataField="parent_name" HeaderText="Parent Name" ReadOnly="true" HeaderStyle-HorizontalAlign="Center"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Left"/>
                                    <telerik:GridBoundColumn DataType="System.String" DataField="parent_email" HeaderText="Parent Email" ReadOnly="true" HeaderStyle-HorizontalAlign="Center"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Left" FilterControlWidth="128"/>   
                                    <telerik:GridBoundColumn DataType="System.String" DataField="parent_phone" HeaderText="Parent Phone" ReadOnly="true" HeaderStyle-HorizontalAlign="Center"
                                        ForceExtractValue="Always" ConvertEmptyStringToNull="true" ItemStyle-HorizontalAlign="Left"/>  
                                </Columns>
                                <PagerStyle Mode="NextPrevNumericAndAdvanced" />
                             </MasterTableView>
        </telerik:RadGrid>


	    </td>
</tr>
</table>
</asp:Content>



